﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Wala.Connection.Objects.Timeline;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;

namespace Wala.Views.Timelines
{
    public class TimelineTemplateSelector : DataTemplateSelector
    {
        public DataTemplate PhotoInfoTemplate { get; set; }
        public DataTemplate StatusInfoTemplate { get; set; }

        protected override DataTemplate SelectTemplateCore
            (object item, DependencyObject container)
        {
            if (item is PhotoInfo)
            {
                return PhotoInfoTemplate;
            }
            else if (item is StatusInfo)
            {
                return StatusInfoTemplate;
            }
            else
            {
                return base.SelectTemplate(item, container);
            }
        }
    }
}
